<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8" import="com.stx.bean.*,java.util.*"%>
    <%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://"
			+ request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
	//获取我的博文列表信息
	List list = (List)request.getAttribute("blogs");
	//BlogUser user = (BlogUser)session.getAttribute("USER");
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>我的全部博文</title>
<link rel="stylesheet" type="text/css" href="<%=basePath %>/css/top.css" />
</head>
<body>
<jsp:include page="top.jsp"></jsp:include>
<table id="blog">
   <tr>
     <td>id</td>
     <td>用户id</td>
     <td>标题</td>
     <td>内容</td>
     <td>操作</td>
   </tr>
   <%
      for(int i=0;i<list.size();i++){
    	  Blog1 blog=(Blog1)list.get(i);
    	  //BlogUser b=new BlogUser();
    	  BlogUser user=(BlogUser)request.getSession().getAttribute("USER");
    	  %>
    	      <tr class="show">
			     <td><%=blog.getId() %></td>
			     <td><%=user.getId() %></td>
			     <td><%=blog.getTitle() %></td>
			     <td><%=blog.getContent() %></td>
			     <td>
			     <a href="<%=basePath %>blogbyid?id=<%=blog.getId() %>">编辑</a> 
			     <a href="<%=basePath %>blogdelsel?id=<%=blog.getId() %>">删除</a> 
			      </td>
              </tr>
    	  <%
      }
   %>
</table>
</body>
</html>